package com.google.gwt.sample.dynatablerf.client.views;

import com.google.gwt.sample.dynatablerf.client.presenters.MainPresenter.MainDisplay;
import com.google.gwt.sample.dynatablerf.client.theme.GrifoTheme;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.DockPanel;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.TabLayoutPanel;

public class MainView extends Composite implements MainDisplay {

	private TabLayoutPanel tabLayoutPanel;
	
	public MainView() {
		DockPanel dockPanel = new DockPanel();
		dockPanel.setSize("100%", "100%");
		initWidget(dockPanel);
		
		Label label = GrifoTheme.getLabelDockTeste();
		label.setText("NORTE");
		
		dockPanel.add(label, DockPanel.NORTH);
		
		tabLayoutPanel = GrifoTheme.getTabLayoutPanel();
		
		tabLayoutPanel.setSize("100%", "500px");
		
		dockPanel.add(tabLayoutPanel, DockPanel.CENTER);
		
		Label label2 = GrifoTheme.getLabelDockTeste();
		label2.setText("SUL");
		
		dockPanel.add(label2, DockPanel.SOUTH);
		
	}

	@Override
	public TabLayoutPanel getTabLayoutPanel() {
		return tabLayoutPanel;
	}

}
